﻿<local:DocumentBase x:Class="WPFExcelReport.JLTVK02YF"
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
          xmlns:local="clr-namespace:ReflectionStudio.Components.UserControls;assembly=ReflectionStudio.Core"
                
        xmlns:wep="clr-namespace:WPFExcelReport"
       
       Background="White" 
         Loaded="Window_Loaded" 
     >
    <local:DocumentBase.Resources>
    </local:DocumentBase.Resources>
    <Grid DataContext="{Binding}" Width="1021">
        <Grid.RowDefinitions>
            <RowDefinition Height="100" />
            <RowDefinition Height="150*" />
            <RowDefinition Height="200*" />
            <RowDefinition Height="50*" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="512*"></ColumnDefinition>
            <ColumnDefinition Width="463*"></ColumnDefinition>
            <ColumnDefinition Width="49*" />
        </Grid.ColumnDefinitions>        
        <StackPanel Grid.ColumnSpan="2" Orientation="Vertical" Margin="0,0,19,66">
            <WrapPanel Width="950">
                <Label Content="规格(模糊查询但不可输入中文)："    Width="272" Margin="10,0,0,0"  HorizontalAlignment="Left"   FontSize="18" VerticalAlignment="Center" Foreground="#FF141111" />
                <TextBox Name="txtDESCR" Width="256" Margin="5,0,0,0"  HorizontalAlignment="Left" Background="YellowGreen" Panel.ZIndex="1"
                         KeyUp="txtART_KeyUp" CharacterCasing="Upper" MaxLength="15" FontSize="18" Foreground="#FF141111" Height="33" />
                
            </WrapPanel>
        </StackPanel>
        <StackPanel Margin="0,35,19,0" Grid.RowSpan="4" Grid.ColumnSpan="2">
            <WrapPanel Width="950">
                <Label Content="业务员下单日期从" Height="26" HorizontalAlignment="Left" Margin="10,5,0,0" Name="label3" VerticalAlignment="Top" Width="130" FontSize="16" />
                <DatePicker Height="25" HorizontalAlignment="Left" Margin="0,2,0,0" Name="FROM_DN_DATE" VerticalAlignment="Top" Panel.ZIndex="2"
                                    SelectedDateChanged ="FROM_DN_DATE_SelectedDateChanged" Width="113" />
                <Label Content="至" Height="28" HorizontalAlignment="Left" Margin="10,5,0,0" Name="label4" VerticalAlignment="Top" Width="19" FontSize="16" />
                <DatePicker Height="25" HorizontalAlignment="Left" Margin="0,2,0,0" Name="END_DN_DATE" VerticalAlignment="Top" Panel.ZIndex="3"
                                    SelectedDateChanged ="END_DN_DATE_SelectedDateChanged" Width="112" />
                <Button Content="查询订单" Height="33" Margin="10,0,0,0"  Name="btnQuery" Width="64" Panel.ZIndex="4"
                        Click="btnQuery_Click"/>
                <Button Content="导出订单" Height="33" Margin="10,0,0,0"  Name="btnEXCEL" Width="65" Panel.ZIndex="5"
                        Click="btnEXCEL_Click"/>
            </WrapPanel>
            <WrapPanel Width="952">
                <DataGrid CanUserReorderColumns="True"  
          CanUserResizeRows="True" CanUserSortColumns="True"
            AutoGenerateColumns="False"   
                  EnableRowVirtualization="True"  
                  Width="950"
                  Height="530" FontSize="11"
                  EnableColumnVirtualization="True"  
                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                  RowDetailsVisibilityMode="VisibleWhenSelected" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
                                IsSynchronizedWithCurrentItem="True" Opacity="10" Visibility="Visible"
                               ItemsSource="{Binding}" x:Name="MasterDg" 
                               Grid.ColumnSpan="2" Margin="0,5,0,0" Grid.RowSpan="3" Grid.Row="1">
<!--VKPPOSTYP	TYPE	VKPNEUDAT	CUSTOMER	CUNAME	VKPAUFKRS	ORDERNO	ITEM	DESCR	
       ARTGRP	ARTNAME	VKPWUTERM	VKPLIEFTERM	VKPVERZTERM1	VKPVERZTERM2	VKPVERZTERM3	
                    VKPVERZTERM4	STAFF	SACHB	STATUS	VKPERL	REMARK-->
                    <DataGrid.Columns>
                        <DataGridTextColumn Binding="{Binding Path=TYPE}" Header="订单类型" Width="SizeToCells" MinWidth="50" />
                        <DataGridTextColumn Binding="{Binding Path=VKPNEUDAT}" Header="下单日期" Width="SizeToCells" MinWidth="30" />
                        <DataGridTextColumn Binding="{Binding Path=CUNAME}" Header="客户" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPAUFKRS}" Header="前缀" Width="SizeToCells" MinWidth="30" />
                        <DataGridTextColumn Binding="{Binding Path=ORDERNO}" Header="订单号" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=ITEM}" Header="行号" Width="SizeToCells" MinWidth="30" />
                        <DataGridTextColumn Binding="{Binding Path=DESCR}" Header="规格" Width="SizeToCells" MinWidth="50" MaxWidth="100" />
                        <DataGridTextColumn Binding="{Binding Path=ARTNAME}" Header="品名" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPLIEFTERM}" Header="研发交期" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPVERZTERM1}" Header="坯布完成日期" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPVERZTERM2}" Header="后整理完成日期" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPVERZTERM3}" Header="研发给销售日期" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPVERZTERM4}" Header="销售寄样日期" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=STAFF}" Header="设计师" Width="SizeToCells" MinWidth="30" />
                        <DataGridTextColumn Binding="{Binding Path=SACHB}" Header="跟单员" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=STATUS}" Header="状态" Width="SizeToCells" MinWidth="40" />
                        <DataGridTextColumn Binding="{Binding Path=VKPERL}" Header="是否完成" Width="SizeToCells" MinWidth="30" />
                        <DataGridTextColumn Binding="{Binding Path=REMARK}" Header="备注" Width="SizeToCells" MinWidth="40" MaxWidth="100"/>
                        
                    </DataGrid.Columns>
                </DataGrid  >
            </WrapPanel>
        </StackPanel>
    </Grid>
</local:DocumentBase>
